1. Field of the Invention
This invention relates to the field of hard disk controller systems that are compatible with the IBM AT BIOS (Basic Input/Output System) and in particular the AT interface between host and microprocessor.
2. Background Art
Computers and their associated disk drives are used for storing large amounts of data. Typically, data is stored on a magnetic disk in a series of concentric tracks on the surface of the disk. A read/write head moves back and forth radially on the disk so that it can be selectively positioned over one of the tracks. To effectively read and write data, it is necessary that the position of the tracks in relation to the head be known. In addition to knowing which track the head is over, it is necessary to know where on that particular track the head is positioned. A servo pattern is used to provide position information. One type of servo pattern is the sector servo, which comprises bursts of servo information disposed on a disk surface in between data areas.
Also, it is necessary to know at which circumferential position in the track the head is located. This is done by an "index" which is generally defined at a specific circumferential location in the servo pattern to indicate the start/end location of each data track. Also necessary for proper addressing is cylinder information which is a combination of all the tracks that are currently accessed by the heads in a drive. Once in position over a track, the head remains in place as the track rotates beneath it, allowing the head to read or write data on the track.
The host computer communicates with the disk drive through an interface such as the AT Bus interface. An AT Bus interface often contains several registers that the host uses to communicate with the disk drive controller. The entire set of registers is collectively referred to as an AT Task File. The control registers of the interface are used for writing and reading data and also issuing commands between the host and the disk microprocessor. The control registers also provide status information including error status to the host. Other registers of the AT Task File specify the physical address for a read or write command. All of these registers that comprise the interface are necessary for proper coordination between the host and drive.
Thus, data information as well as status information from the disk is then provided to the AT Bus interface before the data information is provided to the host computer. The AT task file registers within the AT interface receives the status information from the drive for updating the registers. After each data sector is transferred, AT task file registers of the AT interface are updated in order to indicate the physical address of the sector of data being transferred.
A block diagram of the AT interface is given in FIG. 4. The host computer block 120 and disk drive microprocessor 110 are coupled to AT interface 130 through bus line 160. AT interface block 130 is also coupled to AT task file block 140 which is a part of AT interface 130. AT task file 140 is coupled to microprocessor 110. AT interface is coupled to other electronics block 170 which is coupled to Head Drive Assembly (HDA) 150. Head Drive Assembly 150 is also coupled to microprocessor 110. The other electronics block 170 along with AT interface 130 make up the disk controller of the disk drive. In operation, commands are sent to the disk drive to read or write data. This data is transferred back to the computer. When the data information is transferred through the AT interface 130 and bus 160 to the host 120 or microprocessor 110, AT task file block 140 is updated by the microprocessor with the status information. These task file registers (that are updated after each data block or sector is transferred for providing the physical address of data sectors being transferred) comprise a sector count register, a sector number register, a drive/head number register, a cylinder low register and a cylinder high register.
The AT sector number register is a dual-ported, read/write register available to both the host and microprocessor. This register is an 8 bit parameter register used to provide the sector ID. This register is used to specify the starting sector number for the current/read write sector command. This register is usually incremented by the local microcontroller after each sector is transferred by the host and controller, or transferred from the controller to the host (read operation).
When the sector number register is incremented high enough so that the register value reaches the largest sector ID on the track, (the upper bound of the sector number register), the next time a data sector is transferred, the microprocessor must reset the register for proper updating. The microprocessor stores this upper bound value and prevents the register from incrementing above this value.
The AT sector count register is used to specify the number of sectors to be transferred during a read/write sector command. This register is decremented by the local microcontroller usually after each sector is transferred. If this register is loaded with zero then 256 sectors are transferred.
The AT drive/head register is an 8 bit register used by the host to specify the head number and the drive number. In addition, bit four of this register is used to select one of the two drive status registers, drive zero status register or drive one status register, accessible from the host. Bits 3-0 contain the binary coded address of the head to be selected. In previous AT task files, the microprocessor changes the head address as each track or cylinder boundary is crossed.
The AT cylinder low register is used to specify the lower eight bits of the disk cylinder address. This register, in conjunction with the cylinder high register, constitutes a 16-bit cylinder address. This register is incremented by the local microcontroller usually as each cylinder boundary is crossed. At the end of the command, this register is updated to reflect the current cylinder number.
The cylinder high register contains the high order bits of the starting cylinder address for any disk access. At the end of the command, this register is updated to reflect the current cylinder number. The most significant bits of the cylinder address are loaded into the cylinder high register.
Upon completion of each data sector transfer, the registers described above must be updated with the current sector, head, and cylinder information. This process, in prior art, is typically performed by the system microprocessor. This requires that the microprocessor maintain, increment and reload each of the task file registers for each block of data transferred. Unfortunately, this reduces the available microprocessor bandwidth and increases the time over-head in transferring data from the disk drive to the host computer. It is desirable to have the microprocessor bandwidth free from maintaining the task file register values. If a single microprocessor is used in disk drives to support all the drive functions, including task file updates, microprocessor bandwidth may not be available to maintain the task file register values. It is desirable to free the microprocessor from updating the task file registers.